package com.ruoyi.tracks.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.tracks.mapper.TracksTagsMapper;
import com.ruoyi.tracks.domain.TracksTags;
import com.ruoyi.tracks.service.ITracksTagsService;

/**
 * 歌曲tagService业务层处理
 * 
 * @author lin
 * @date 2025-03-04
 */
@Service
public class TracksTagsServiceImpl implements ITracksTagsService 
{
    @Autowired
    private TracksTagsMapper tracksTagsMapper;

    /**
     * 查询歌曲tag
     * 
     * @param trackId 歌曲tag主键
     * @return 歌曲tag
     */
    @Override
    public TracksTags selectTracksTagsByTrackId(Long trackId)
    {
        return tracksTagsMapper.selectTracksTagsByTrackId(trackId);
    }

    /**
     * 查询歌曲tag列表
     * 
     * @param tracksTags 歌曲tag
     * @return 歌曲tag
     */
    @Override
    public List<TracksTags> selectTracksTagsList(TracksTags tracksTags)
    {
        return tracksTagsMapper.selectTracksTagsList(tracksTags);
    }

    /**
     * 新增歌曲tag
     * 
     * @param tracksTags 歌曲tag
     * @return 结果
     */
    @Override
    public int insertTracksTags(TracksTags tracksTags)
    {
        return tracksTagsMapper.insertTracksTags(tracksTags);
    }

    /**
     * 修改歌曲tag
     * 
     * @param tracksTags 歌曲tag
     * @return 结果
     */
    @Override
    public int updateTracksTags(TracksTags tracksTags)
    {
        return tracksTagsMapper.updateTracksTags(tracksTags);
    }

    /**
     * 批量删除歌曲tag
     * 
     * @param trackIds 需要删除的歌曲tag主键
     * @return 结果
     */
    @Override
    public int deleteTracksTagsByTrackIds(Long[] trackIds)
    {
        return tracksTagsMapper.deleteTracksTagsByTrackIds(trackIds);
    }

    /**
     * 删除歌曲tag信息
     * 
     * @param trackId 歌曲tag主键
     * @return 结果
     */
    @Override
    public int deleteTracksTagsByTrackId(Long trackId)
    {
        return tracksTagsMapper.deleteTracksTagsByTrackId(trackId);
    }
}
